﻿// --------------------------------------------------------------------------------------------------------------------
// <copyright file="ServiceBase.cs" company="Skymate">
//   Copyright © 2015 Skymate. All rights reserved.
// </copyright>
// <summary>
//   定义ServiceBase类型.
// </summary>
// --------------------------------------------------------------------------------------------------------------------

namespace Skymate
{
    using Castle.Core.Logging;

    /// <summary>
    /// 服务基础类.
    /// </summary>
    public abstract class ServiceBase
    {
        #region Fields

        /// <summary>
        /// The logger.
        /// </summary>
        private ILogger logger;

        #endregion

        #region Properties

        /// <summary>
        /// Gets the logger.
        /// </summary>
        protected ILogger Logger
        {
            get
            {
                return this.logger ?? (this.logger = NullLogger.Instance);
            }
        }

        #endregion
    }
}